<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Minuman extends CI_Model {
	
    
	public function get_minuman(){

		$this->db->order_by('id_minuman');
		$rs = $this->db->get('minuman');
		return $rs->result();
	}

	function AddMinuman($data){
	$this->db->insert('minuman',$data);

	}

	function EditMinuman($id){
	$this->db->where('id_minuman',$id);
	$rs = $this->db->get('minuman');
	return $rs->result();
	}

	function updateMinuman($id,$data){
	$this->db->where('id_minuman',$id);
	$this->db->update('minuman',$data);
	}

	public function hapus($id){
 	$this->db->where('id_minuman', $id);
	$this->db->delete('minuman');	
/*	$query = $this->db->query('delete from kategori where id_kategori=1');*/
	}
}
